const UsersService = require('../service/users')

class UsersController {
  async add(ctx) {
    let data = await UsersService.add(ctx)
    ctx.body = data;
  }
  async page(ctx) {
    let data = await UsersService.page(ctx)
    ctx.body = data;
  }
  async delete(ctx) {
    let data = await UsersService.delete(ctx)
    ctx.body = data;
  }
  async search(ctx) {
    let data = await UsersService.search(ctx)
    ctx.body = data;
  }
  async update(ctx) {
    let data = await UsersService.update(ctx)
    ctx.body = data;
  }
}

module.exports = new UsersController